package com.Dao;

import java.sql.ResultSet;
import java.sql.SQLException;

import util.DBHelp;
import util.RowMapper;


import com.entity.employProject;

public class employeeProjectSavaDao {

	private DBHelp<employProject> db = new DBHelp<employProject>();
	
	public void save(employProject ep) {
		String sql ="INSERT INTO t_employee_project (employeeid,projectid)VALUES(?,?)";
		db.executeSQL(sql,ep.getEmployeeid(),ep.getProjectid());
	}


	class Mr implements RowMapper<employProject>{
		public employProject mapperRow(ResultSet rs) throws SQLException {
			employProject em=new employProject();
			em.setEmployeeid(rs.getInt("employeeid"));
			em.setProjectid(rs.getInt("projectid"));
		return em;
		}
		}
}
